# == Schema Information
# Schema version: 6
#
# Table name: categories
#
#  id            :integer(11)     not null, primary key
#  blog_id       :integer(11)     
#  name          :string(255)     
#  entries_count :integer(11)    default("0")
#  position      :integer(11)     
#

class Category < ActiveRecord::Base
  belongs_to :blog
  acts_as_list :scope => :blog_id
  
  has_many :entries
  
  validates_presence_of :name 
  validates_length_of :name, :maximum => 10
end
